package com.eazy.lkv2.web.controller;

import java.io.Serializable;
import java.util.List;

import org.springframework.web.bind.ServletRequestBindingException;
import org.springframework.web.bind.ServletRequestUtils;

public abstract class CrudController<Entity, PK extends Serializable> extends BaseController<Entity, Serializable> {

	public List<Entity> list() {
		return queryByList(null);
	}
	
	public String getPara(String name) {
		try {
			return ServletRequestUtils.getStringParameter(getRequest(), name);
		} catch (ServletRequestBindingException e) {
			e.printStackTrace();
		}
		return null;
	}
}
